home *** CD-ROM | disk | FTP | other *** search
- #!/bin/sh
-
- set -e
-
- APP_PROFILE="usr.bin.firefox-3.5"
- APP_CONFFILE="/etc/apparmor.d/$APP_PROFILE"
- APP_DISABLE="/etc/apparmor.d/disable/$APP_PROFILE"
- if [ "$1" = "install" ] || [ "$1" = "upgrade" ]; then
- # Disable AppArmor profile on install or upgrade from earlier than when we
- # first shipped the profile if the user does not already have a profile
- # defined
- if dpkg --compare-versions "$2" lt 3.5.2+nobinonly-0ubuntu3 || echo "$2" | egrep -q '(9.04|8.10|8.04)' ; then
- if [ ! -e "$APP_CONFFILE" ]; then
- mkdir -p `dirname $APP_DISABLE` 2>/dev/null || true
- ln -sf $APP_CONFFILE $APP_DISABLE
- fi
- fi
- fi
-
-